<template>
  <div>
    <!-- -->
    <el-pagination
      @size-change="handleSizeChange"
      @current-change="handleCurrentChange"
      :current-page="page"
      :page-sizes="[20, 30, 40]"
      :page-size="10"
      background
      layout="total, sizes, prev, pager, next, jumper"
      :total="total">
    </el-pagination>
  </div>
</template>

<script>

export default {
    props :{
        total :{
            type : Number
        },
        page: {
            type: Number
        }
    },

  data() {
    return {
        currentPage4: 1
    };
  },

  mounted() {
    
  },

  methods: {
    
      handleSizeChange(val) {
        // console.log(`每页 ${val} 条`);
        this.$emit('size', val);
      },
      handleCurrentChange(val) {
        // console.log(`当前页: ${val}`);
        this.$emit("page" , val)
      }
  },
};
</script>